choicescriptdevfandomcom-20200216-history
Index.html
This article is about the index.html file located in the mygame folder, along with mygame.js; the other index.html file is explained in another article. You can open your game using this index.html file or the other index.html file (covered in another article). In this index.html file, you can customize the title that appears when you open your game, you can add an author, you can change the text displayed at the bottom of the screen, you can change the text that displays when and if javascript or the cookies are disabled for that browser (the ChoiceScript games need to cookies enabled to work) and here you can add/remove stats buttons (more thoroughly explained in another article). You can also change the description the search engines will see if your game is published on an website. Firstly of all, open the index.html file with a text editor. Notepad is a rudimentary text editor, but it's recommended that you use Notepad++, or another advanced text editor. 'Customizing the game's title' You need to look for these two lines (which will not be near each other): My First ChoiceScript Game and Multiple Choice Example Game | My First ChoiceScript Game The first controls what is displayed on the page itself, while the second controls what the the web browser calls the game. All you need to do is replace the "My First ChoiceScript Game" and "Multiple Choice Example Game | My First ChoiceScript Game" text with the title you want your game to have. 'Adding an author to your game' Right under the first of the above two lines, you place another line, similar to it but a little tweaked: by Game Author Change the "by Game Author" text to your name, your company's name or to whatever else you would like to be displayed as a second header, and that's it. 'Customizing the text at the bottom of the screen' Look for this line (close to the end): Love it? Hate it? Write us at support@choiceofgames.com You can change that to whatever you want, or you can add further lines just after this that will display under it or above it (according to where you want to place them). Here's how you write lines/mails/links: In HTML, signifies the beginning of a paragraph, and the < /p> signifies the end of it; you can add how many you want, just don't make the page look too full of text (it's entirely up to you, but the less text, the better it looks). For example, you can do this: Do you like this game? I'm glad you do! And this text will display in two lines, just as you wrote it. If however you want to add your e-mail, you just have to tweak the line a bit; you change this part: href='mailto:support-external@choiceofgames.com'> to your email, this way: href='mailto:feedback@yahoo.com'> This mail is the mail you will be taken to if you click the link. The following part: support@choiceofgames.com is the text that displays as the clickable link, and you can change it to whatever you want. If you want to add a link, you can add this line: Displayed Clickable Text 'Changing the text displayed if javascript or cookies are disabled' You need to look for these lines (right at the end): This is just an example game. This game requires JavaScript; please enable JavaScript and refresh this page. If you can't get the game to work, please write to us at support-external@choiceofgames.com for assistance. Change them as you want; all you have to do is keep the and tags. You can add lines of text, mails and links as previously stated. Changing the description search engines see You need to look for these lines: Multiple Choice Example Game | My First ChoiceScript Game You can change everything between the and tags, but you have to keep the | bar (the first part is the title, the second part is the subtitle that will be displayed in the search engines). As for the description, you can change everything between the second pair of quotation marks: "This is a description of the game that search engines can see." Try writing a descriptive title and description so that it makes people want to check out your game if it pops out in any of their searches on search engines. Back to the index. Related Articles *Structure of a ChoiceScript game *Stats Buttons Category:Tutorials Category:ChoiceScript files